@inject ISearchService searchService 

<div class="imagebrowser">
    <DetailedErrorBoundary>
        <SearchBar OnGridSizeChanged="GridSizeChanged"/>
        <ImageGrid CurrentGridSize="@gridSize"/>
    </DetailedErrorBoundary>
</div>

@code {
    private GridImageSize gridSize { get; set; }

    private void GridSizeChanged(GridImageSize newSize)
    {
        gridSize = newSize;
        StateHasChanged();
    }

}